KERNEL_DIR = /home/xgj/workspace/project/rsu7012/kernel/linux-3.10.79

export PATH := $(PATH):/home/xgj/workspace/project/rsu7012/toolchains/arm-eabi/bin

ARCH=arm
CROSS_COMPILE=arm-eabi-
export  ARCH  CROSS_COMPILE

obj-m += hello_drv.o

build: hello_drv hello_drv_asm

hello_drv:
	$(MAKE) -C $(KERNEL_DIR) M=$(CURDIR) modules

hello_drv_asm:
	@arm-eabi-objdump -D hello_drv.ko > hello_drv.dis
kernel_asm:
	@arm-eabi-objdump -D /home/xgj/workspace/project/rsu7012/kernel/linux-3.10.79/vmlinux > vmlinux.dis

.PHONY:clean
clean:
	$(MAKE) -C $(KERNEL_DIR) M=$(CURDIR) clean